import {baseRequest} from '@/utils/request'

const request = (url, ...arg) => baseRequest(`/process/version/` + url, ...arg)

export default {
	async getById(data) {
		return await request('get_by_id', data, 'post')
	},
	async setStatusFlag(data) {
		return await request('set_status_flag', data, 'post')
	},
	async removeById(data) {
		return await request('remove_by_id', data, 'post')
	},
	async save(data) {
		return await request('save', data, 'post')
	},
	async saveXml(data) {
		return await request('content/save_xml', data, 'post')
	},
	async setLatestFlag(data) {
		return await request('set_latest_flag', data, 'post')
	},
	async queryList(data) {
		return await request('list', data, 'post')
	},
	async getByProcessIdAndVersion(data) {
		return await request('get_by_process_and_version', data, 'post')
	},
}

